package org.ch00.test08;

import java.util.Scanner;

/*
 * @author XCH
 * @date 2025 - 03 - 07 - 15:31
 */
public class MainTest {
    public static void main(String[] args) {
        String sourcePath = "C:\\Users\\xiaoc\\Desktop\\source.txt";  // 源文件路径
        String destinationPath = "C:\\Users\\xiaoc\\Desktop\\destination.txt";  // 目标文件路径

        // 创建用户线程实例
        FileCopyThread fileCopyThread = new FileCopyThread(sourcePath, destinationPath);

        // 创建守护线程实例
        ProgressThread progressThread = new ProgressThread(fileCopyThread);
        progressThread.setDaemon(true);  // 设置为守护线程

        // 启动线程
        progressThread.start();
        fileCopyThread.start();
    }
}
